#include "test.h"

#include <iostream>

bool My_Threshold(HeadNode<float>* N)
{
    int s = N->Get_Num_Inputs();

    if (N->Evaluate() >= 1)
        return 1;
    else
        return 0;
}

int main()
{
    HeadNode<float> My_NodeA;
    BodyNode<float> My_NodeC;

    My_NodeA.Set_Threshold_Func(My_Threshold);
    My_NodeC.Set_Threshold_Func(My_Threshold);

    My_NodeC.Add_Source(&My_NodeA, 0.7);
    My_NodeC.Add_Source(1.2 , 0.4);

    My_NodeA.Add_Input(1.0, 0.5);
    My_NodeA.Add_Input(0.5, 1.2);

    My_NodeC.Update_Inputs();

    std::cout << My_NodeA.Get_Output() << " ";
    std::cout << My_NodeC.Get_Output() << "\n";

    return 0;
}

